// 引入vue-router中模块 
import { createRouter, createWebHistory, RouteRecordRaw } from 'vue-router'
// 引入首页的vue模块 
import Layout from '../layout/Index.vue'

// ==== 创建路由转发的记录明细 =====
const routes: Array<RouteRecordRaw> = [
    {path: '/', name: 'Layout', component: Layout},
]

// ==== 创建一个路由的对象 ======
const router = createRouter({
    history: createWebHistory(),
    routes
})

// 暴露  --- return 
export default router
